(function myModule()
{
    //私有数据
    var msg="my atguigu";
    function doSomething()
    {
        console.log("doSomethig()="+msg.toUpperCase());
    }
    function doOtherthing()
    {
        console.log("doOtherthing()="+msg.toLowerCase());
    }
    //如果不对外暴露函数的话，该函数就无效

    //给window添加一个属性myModule2
    window.myModule2=
    {
        doSomething:doSomething,
        doOtherthing:doOtherthing
    };
})()